package com.dao;

import com.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserDao {

    //查询所有user
    List<User> getAllUser();

    //根据用户名修改年龄
    Integer updateUserAgeByUserName(@Param("userName") String userName, @Param("age") Integer age);

    //根据用户名删除
    Integer delUserByUserName(@Param("userName") String userName);

    //插入一条数据#{userName},#{age},#{breed}
    Integer insertUser(@Param("userName")String userName,
                       @Param("age")Integer age,
                       @Param("breed")String breed);

    //根据userName查
    User getUserByUserName(@Param("userName")String userName);
}
